//
//  AlibabaSdk.m
//  lovebaby
//
//  Created by 陈星华 on 2020/3/14.
//  Copyright © 2020年 Facebook. All rights reserved.
//

//#import "CalendarManager.h"
//#import <React/RCTLog.h>
//
//@implementation CalendarManager
//
//RCT_EXPORT_MODULE();
//
//RCT_EXPORT_METHOD(addEvent:(NSString *)name location:(NSString *)location)
//{
//  RCTLogInfo(@"Pretending to create an event %@ at %@", name, location);
//}
//
//@end


#import <Foundation/Foundation.h>
#import "AlibabaSdk.h"
#import "AlibabaModule.h"

@implementation AlibabaSdk

- (dispatch_queue_t)methodQueue
{
  return dispatch_get_main_queue();
}


RCT_EXPORT_MODULE();

RCT_EXPORT_METHOD(asyncInit: (RCTResponseSenderBlock)callback)
{
    [[AlibabaModule sharedInstance] asyncInit:callback];
}
RCT_EXPORT_METHOD(showLogin: (RCTResponseSenderBlock)callback)
{
  [[AlibabaModule sharedInstance] showLogin:callback];
}
RCT_EXPORT_METHOD(isLogin: (RCTResponseSenderBlock)callback)
{
  [[AlibabaModule sharedInstance] isLogin:callback];
}
RCT_EXPORT_METHOD(getUserInfo: (RCTResponseSenderBlock)callback)
{
   [[AlibabaModule sharedInstance] getUserInfo:callback];
}
RCT_EXPORT_METHOD(logout: (RCTResponseSenderBlock)callback)
{
   [[AlibabaModule sharedInstance] logout:callback];
}
RCT_EXPORT_METHOD(showPage: (NSDictionary *)param callback: (RCTResponseSenderBlock)callback)
{
   RCTLog(@"not implement=======================showPage");
  [[AlibabaModule sharedInstance] showPage:param callback:callback];
}
RCT_EXPORT_METHOD(addEvent: (NSDictionary *)param location:(NSString *)location)
{
  RCTLogInfo(@"Pretending to create an event ================== ");
}


@end
